package com.weiyuwqj.server.service.account.module.action;

import com.weiyuwqj.api.constant.DealType;
import com.weiyuwqj.api.util.IpUtils;

import java.math.BigDecimal;
import java.util.Date;

/**
 * Created by pg on 15/11/28.
 */
public class VerifyCashDealAction extends AbstractDealAction {

    @Override
    public void instance(Integer userId, BigDecimal operMoney, String remark) {
        super.instance(userId, operMoney, remark);
        log.setOperType(DealType.USER_CASH_SUCCESS);
    }

    @Override
    public void dealAccount() {
        log.setFrozen(log.getOperMoney().negate());
        log.setBudgetType(2);
        log.setAddtime(new Date());
        log.setAddip(IpUtils.get());
    }

}
